using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;

namespace Cartoon
{
    public partial class AppAblout : UserControl
    {
        Uri m_Url;

        public AppAblout()
        {
            InitializeComponent();
        }

        public string Url
        {
            set
            {
                m_Url = new Uri(value);
            }
        }

        public void Activate()
        {
            if (m_Url == null)
                return;

            m_WebBrowser.Navigate(m_Url);
        }       

        private void AppAblout_Load(object sender, EventArgs e)
        {            
            Activate();           
        }

        private void m_WebBrowser_DocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)
        {
            //HtmlDocument dom = m_WebBrowser.Document;
            //HtmlElement e2 = dom.GetElementFromPoint(new Point(49, 55));
            //e2.InvokeMember("click");

            //int  n = m_WebBrowser.Document.Links.Count;
            //foreach (HtmlElement link in m_WebBrowser.Document.Links)
            //{
            //    string s = link.GetAttribute("href");
            //}
        }    
    }
}
